require.config({
    baseUrl : "../modules",
    paths:{

    }
})
const list = document.querySelector(".hot-bottom");
require(["getGoods","renderList","setlistLocal"],function(getGoods,renderList,setlistLocal){

    getGoods(res=>{
        renderList(res, list);
    })
    list.onclick = function(eve){
        const e = eve || window.event;
        const target = e.target || e.srcElement;
        if(target.className ==="btn2"){
            
            const id = target.parentNode.getAttribute("index");
            price = target.parentNode.children[0].children[3].children[0].innerHTML;
            // console.log(target.parentNode.children[0].children[3].children[0].innerHTML);
            setlistLocal(id, price);
        }
    }
})





